<h1>hello products</h1>

<%= form_for :product,url:products_path  do |f| %>
<%if @product.errors.any?%>
	<div id="error_explanation">
	    <h2><%= pluralize(@product.errors.count, "error") %> prohibited
	      this article from being saved:</h2>
	    <ul>
	    <% @product.errors.full_messages.each do |msg| %>
	      <li><%= msg %></li>
	    <% end %>
	    </ul>
	 </div>
<% end%>
  <p>
    <%= f.label :title %><br>
    <%= f.text_field :title %>
  </p>
 
  <p>
    <%= f.label :text %><br>
    <%= f.text_area :text %>
  </p>
 
  <p>
    <%= f.submit %>
  </p>
<% end %>
<%= link_to 'Back',products_path%>